당시 의 사실 실행 시 자바 의 다 태 성 실현 void fun() { System.out.println(“This is subC”); } } class Test { public static void main(String[] args) { superA a; subB b = new subB(); subC c = new subC(); a=b; a.fun(); (1) a=c; a.fun();... 운행 하 다.유행 하 다당시 의 사실이루어지다현 JJaavvaa 의많다다 형태도성질
실행 시 자바 의 다 태 성 실현 void fun() { System.out.println(“This is subC”); } } class Test { public static void main(String[] args) { superA a; subB b = new subB(); subC c = new subC(); a=b; a.fun(); (1) a=c; a.fun();... 운행 하 다.유행 하 다당시 의 사실이루어지다현 JJaavvaa 의많다다 형태도성질